﻿using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace One.Models
{ 
    [Table("answer")]
    public class Answer
    {
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        public int Id { get; set; }
        
        [MaxLength(100)]
        public string QuestionTitle { get; set; }
        
        [MaxLength(100)]
        public string AnswerTitle { get; set; }
        
        public string AnswerContent { get; set; }
        
        public string AnswerSummary { get; set; }

        public DateTime MakeTime { get; set; }

        [MaxLength(100)]
        public string AskerName { get; set; }

        [MaxLength(200)]
        public string AskerAvatar { get; set; }

        [MaxLength(100)]
        public string AuthorName { get; set; }

        [MaxLength(200)]
        public string AuthorAvatar { get; set; }

        /// <summary>
        /// 责任编辑
        /// </summary>
        public string ChargeEditor { get; set; }

        //public string StartVideo { get; set; }

        //public int AuthorId { get; set; }


        //public int AskerId { get; set; }

        ///// <summary>
        ///// 回答者
        ///// </summary>
        ////[ForeignKey("AuthorId")]
        //public virtual Author Author { get; set; }

        ///// <summary>
        ///// 提问者
        ///// </summary>
        ////[ForeignKey("AskerId")]
        //public virtual Author Asker { get; set; }
    }
}
